import request from '@/config/axios'

// 获得列表
export const getDynamicList = (params: any) => {
  return request.get({ url: '/community/dynamic/list', params })
}
// 创建信息
export const createDynamic = (data: any) => {
  return request.post({ url: '/community/dynamic/create', data })
}
// 获取信息
export const getDynamic = (id: any) => {
  return request.get({ url: `/community/dynamic/${id}` })
}
// 修改信息
export const updateDynamic = (data: any) => {
  return request.put({ url: '/community/dynamic/update', data })
}
// 删除信息
export const deleteDynamic = (id: any) => {
  return request.delete({ url: `/community/dynamic/${id}` })
}
// 审核动态
export const auditDynamic = (data: any) => {
  return request.put({ url: '/community/dynamic/audit', data })
}

// 查看动态评论列表
export const getDynamicCommentList = (params: any) => {
  return request.get({ url: '/community/dynamic/comment/get/list', params })
}
